home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Delphi Magazine Collection 2001
/
Delphi Magazine Collection 20001 (2001).iso
/
DISKS
/
Issue51
/
ComCorn
/
Unit1.pas
< prev
next >
Wrap
Pascal/Delphi Source File
|
1999-10-11
|
712b
|
43 lines
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
uses ComObj;
{$R *.DFM}
procedure TForm1.Button1Click(Sender: TObject);
var
V1: OleVariant;
I: Integer;
T1: Cardinal;
begin
V1 := CreateOleObject('Word.Application');
T1 := GetTickCount;
for I := 1 to 1000 do
V1.Caption := V1.Caption + 'x';
Caption := IntToStr(GetTickCount - T1);
V1.Visible := True;
end;
end.